<extend name="common:commonTemplate" />
<block name="main_content">
<div id="content">
	<div id="content-header">
		<div id="breadcrumb">
			<a class="tip-bottom" href="index.html"
				data-original-title="Go to Home"><i class="icon-home"></i> 首页</a> <a
				href="#">权限管理</a> <a class="current" href="#">页面资源管理信息列表</a>
		</div>
	</div>
	<div class="container-fluid">
		<div class="row-fluid">
			<div class="span12">
				<div class="widget-box">
					<div class="widget-title">
						<span class="icon"> <i class="icon-info-sign"></i>
						</span>
						<h5>页面资源管理信息</h5>
					</div>
					<div class="widget-content nopadding">
						<form novalidate="novalidate" id="basic_validate"
							name="basic_validate" action="#" method="post"
							class="form-horizontal">
							<div class="control-group">
								<label class="control-label">菜单ID</label>
								<div class="controls">
									<input type="text" id="menu_id" value="{$menu_resource.menu_id}" 
									name="menu_id" readonly="true" />
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">菜单名称</label>
								<div class="controls">
									<input type="text" id="menu_name" value="{$menu_resource.menu_name}" name="menu_name"/>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">页面等级</label>
								<div class="controls">
									<input type="text" id="level" readonly="true" value="{$menu_resource.level_text}" name="level"/>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">父节点</label>
								<div class="controls">
									<input type="text" id="parent_name" readonly="true"  value="{$menu_resource.parent_name}" name="parent_name"/>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">菜单域描述</label>
								<div class="controls">
									<input type="text" id="menu_domain_desc" readonly="true" value="{$menu_resource.menu_domain_desc}" name="menu_domain_desc"/>
								</div>
							</div>
							
							<div class="control-group">
								<label class="control-label">菜单链接</label>
								<div class="controls">
									<input type="text" id="menu_url" value="{$menu_resource.menu_url}" name="menu_url"/>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">是否显示</label>
								<div class="controls">
									<select id="menu_display" name="menu_display">
					                  <option value="1">显示</option>
					                  <option value="0">不显示</option>
					                </select>
								</div>
							</div>
							<div class="control-group">
								<a id="btn_updateMenuResource" class="btn btn-success">修改页面资源管理信息</a> 
							</div>
						</form>
					</div>
				</div>
			</div>
		</div>
	</div>
</div>
</block>


<block name="js_content"> <script>
		//修改页面资源管理信息
		$('#btn_updateMenuResource').bind('click', function(){
			var menu_id = $('#menu_id').val();
			var menu_name = $('#menu_name').val();
			var menu_url = $('#menu_url').val();
			var menu_display = $('#menu_display').val();
			var result = AuthService.UpdateMenuResource(menu_id,menu_name,menu_url,menu_display);
			if (result.IsSuccess == 0) {
				alert(result.ErrorMsg);
				return;
			} else {
				alert('操作成功');
				$('#promoter_status').text('有效');
			}
		});

</script> </block>